Core java - Interview Questions and Answers for 'Jabong.com' | Search Interview Question - javasearch.buggybread.com
Questions
Search
List By Company
List By Topic
Legacy
Tests
Repository
DashBoard
Java
Java 8
Java 7
Java Abbreviations
OCJP / SCJP
Class List
New in Java 8
Java Exceptions
Spring Exceptions
Java Enums
Java 8 Lambda
Java 8 java.time
Big Data
Best Of Java
Discussion
Search
Subscribe
Search Interview Questions
More than 3000 questions in repository.
There are more than 900 unanswered questions.
Click here
and help us by providing the answer.
Have a video suggestion.
Click Correct / Improve and please let us know.
Label / Company
Label / Company / Text
Search
Submit Question
Core java - Interview Questions and Answers for 'Jabong.com' - 3 question(s) found
- Order By Newest
Very Frequently asked to fresh graduates and less experienced. Favorite question in Walk in drives. Frequently asked in Indian Services companies.
Q1.
Difference between Overloading and Overriding ?
Core Java
Ans. Overloading - Similar Signature but different definition , like function overloading.
Overriding - Overriding the Definition of base class in the derived class.
Sample Code for overloading
Sample Code for overriding
Help us improve. Please let us know the company, where you were asked this question
:
Like
Discuss
Correct / Improve
 java   oops   overloading   overriding   oops concepts   basic interview question   overloading vs overriding
Asked in 86 Companies
basic
 
frequent
Correction
Duplicate of Another Question
Company where this question was Asked
Suggestion
Try 1 Question(s) Test
Which of the following can be overridden ?
final instance methods
final static methods
non final instance methods
non final static methods
Related Questions
What are the difference between composition and inheritance in Java?
Explain OOPs
or
Explain OOPs Principles
or
Explain OOPs Concepts
or
Explain OOPs features
or
Tell me something about OOPs
What is the difference between Encapsulation and Abstraction?
What are points to consider in terms of access modifier when we are overriding any method?
What is Polymorphism in Java ?
Can you give a real world example of Encapsulation and Abstraction ?
Why every object constructor automatically call super() in Object before its own constructors?
How compiler handles the exceptions in overriding ?
Difference between Composition and Inheritance ?
Q2.
How can we create objects if we make the constructor private ?
Core Java
Ans. We can do so through a static public member method or static block.
Help us improve. Please let us know the company, where you were asked this question
:
Like
Discuss
Correct / Improve
 java   oops   static   constructor   static method   static block  private
Asked in 1 Companies
Correction
Duplicate of Another Question
Company where this question was Asked
Suggestion
Related Questions
How can we run a java program without making any object?
Similarity and Difference between static block and static method ?
Will the static block be executed in the following code ? Why ?
Is it possible to compile and run a Java program without writing main( ) method?
Explain static blocks in Java ?
Will static block for Test Class execute in the following code ?
Can we initialize member variables within static block ?
How can we execute a Java class independently if it doesn't have a static main method ?
Can we create object in static block ?
Q3.
What will happen if we make the constructor private ?
Core Java
Ans. We can't create the objects directly by invoking new operator.
Help us improve. Please let us know the company, where you were asked this question
:
Like
Discuss
Correct / Improve
 java   oops   constructor   access specifier   private
Asked in 1 Companies
basic
Correction
Duplicate of Another Question
Company where this question was Asked
Suggestion
Try 2 Question(s) Test
How can we create objects if we make the constructor private ?
We can't create objects if constructor is private
We can only create objects if we follow singleton pattern
We can only create one object
We can create new object through static method or static block
What will be the output of following code ?
public class BuggyBread {
private int x;
private Integer y;
private BuggyBread(int x,int y){};
public static void main(String[] args){
BuggyBread buggybread = new BuggyBread(1,2);
System.out.println(buggybread.x);
}
}
compilation error due to private constructor
compilation error due to uninitialized elements
0 null
0 0
Related Questions
What are points to consider in terms of access modifier when we are overriding any method?
Difference between Public, Private, Default and Protected ?
Which access specifiers can be used with top level class ? a. public or default b. public or private c. public or protected d. protected or default
Which access specifier can be used with Class ?
Can we reduce the visibility of the inherited or overridden method ?
Can we instantiate the object of derived class if parent constructor is protected ?
Can we declare an abstract method private ?
What access the variable gets if we don't provide any access specifier ?
Can we reduce the visibility of the overridden method ?
Help us and Others Improve. Please let us know the questions asked in any of your previous interview.
Any input from you will be highly appreciated and It will unlock the application for 10 more requests.
Company Name:
Questions Asked: